package com.zhangjun.taxprovidercomputer8002.controller;

import com.zhangjun.entity.ComputedTax;
import com.zhangjun.entity.Result;
import com.zhangjun.taxprovidercomputer8002.service.ComputeService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @author 张钧
 * @Description
 * @create 2022-09-20 13:11
 */
@RestController
@RequestMapping("compute")
public class ComputeController {

	@Resource
	ComputeService computeService;

	@GetMapping( "/{money}")
	public Result<ComputedTax> computeTax(@PathVariable("money") Long money){
		return computeService.computeTax(money);
	}

}